let ss = [
  {
    to: [100, 10, 20, 30, 40, 50],
    from: [
      10497, 23174, 28203, 29325, 33489, 37000, 29034, 31000, 63023, 84832,
    ],
  },
  {
    to: [200, 10, 20, 30, 40, 50],
    from: [
      10497, 23174, 28203, 29325, 33489, 37000, 29034, 31000, 63023, 84832,
    ],
  },
];
let fromArr = [];
for (let i = 0; i < ss.length; i++) {
  let fromObj = ss[i].to;
  for (let j = 0; j < fromObj.length; j++) {
    let fromArrObj = fromArr[j];
    if (fromArrObj === "" || fromArrObj === undefined) {
      fromArrObj = [];
    }
    fromArrObj.push(fromObj[j]);
    fromArr[j] = fromArrObj;
  }
}
let fromArr1 = [];
fromArr.forEach((item) => {
  let num = 0;
  item.forEach((v) => {
    num = v + num;
  });
  fromArr1.push(num);
});
console.log(fromArr1);
